package yhao.demo.service.erp.workflow.apilist.form.flow;

import io.swagger.annotations.ApiModelProperty;
import org.hibernate.validator.constraints.NotBlank;
import yhao.demo.service.erp.workflow.apilist.enums.flow.FlowNodeType;
import yhao.infra.apilist.validate.IdUnForm;

import javax.validation.constraints.NotNull;

public class FlowNodeTemplateForm extends IdUnForm {
    @ApiModelProperty(value = "节点名称",required = true)
    @NotBlank(message = "节点名称不得为空")
    private String name;

    @ApiModelProperty(value = "是否设置预警",required = true)
    @NotNull(message = "是否设置预警不得为空")
    private Boolean warn;

    @ApiModelProperty("节点类型")
    private FlowNodeType type = FlowNodeType.TASK;

    @ApiModelProperty("预警设置")
    private FlowNodeWarnForm warnForm;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public FlowNodeType getType() {
        return type;
    }

    public void setType(FlowNodeType type) {
        this.type = type;
    }

    public Boolean getWarn() {
        return warn;
    }

    public void setWarn(Boolean warn) {
        this.warn = warn;
    }

    public FlowNodeWarnForm getWarnForm() {
        return warnForm;
    }

    public void setWarnForm(FlowNodeWarnForm warnForm) {
        this.warnForm = warnForm;
    }
}
